﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp1
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("请输入一个四位数的数字");
            string q = Console.ReadLine();
            int y = int.Parse(q);
            Console.WriteLine(q);
            int a = y / 1000;
            int b = y / 100 % 10;
            int c = y / 10 % 10;
            int d = y % 10;
            Console.WriteLine("个位数为："+d);
            Console.WriteLine("十位数为："+c);
            Console.WriteLine("百位数为："+b);
            Console.WriteLine("千位数为："+a);

        }
    }
}
